<!DOCTYPE html>
<html>
<head>
    <meta charset="UTF-8">
    <meta name="viewport"
          content="width=device-width, initial-scale=1.0, user-scalable=no, minimum-scale=1.0, maximum-scale=1.0"/>
    <title>华迅直购</title>
    <link rel="stylesheet" type="text/css" href="css/root.css"/>
    <link rel="stylesheet" type="text/css" href="css/pay/main.css"/>
    <link rel="stylesheet" type="text/css" href="css/order/order.css?ver=2"/>
    <script type="text/javascript" src="js/base/jquery-3.1.1.min.js?ver=2.0.4" charset="utf-8"></script>
    <script type="text/javascript" src="js/base/underscore-min.js"></script>
    <script type="text/javascript" src="js/base/moment.min.js"></script>
    <script src="js/base/api.js"></script>
    <script src="js/base/base.js"></script>
    <script src="js/base/vue-filter.js"></script>
    <script src="js/base/vue.js"></script>

    <script type="text/javascript" src="js/base/magiclamp.js?ver=2.0.3" charset="utf-8"></script>


    <script type="text/javascript" src="js/order/user_goods_order.js?ver=2.0.6" charset="utf-8"></script>
    <!-- Core CSS file -->
    <link rel="stylesheet" href="photoswipe/photoswipe.css">

    <!-- Skin CSS file (styling of UI - buttons, caption, etc.)
         In the folder of skin CSS file there are also:
         - .png and .svg icons sprite,
         - preloader.gif (for browsers that do not support CSS animations) -->
    <link rel="stylesheet" href="photoswipe/default-skin/default-skin.css">

    <!-- Core JS file -->
    <script src="photoswipe/photoswipe.min.js"></script>

    <!-- UI JS file -->
    <script src="photoswipe/photoswipe-ui-default.min.js"></script>

</head>
<body>
<div id="user_goods_order_page">
    <header>
        <a @click="page_back" v-if="baseConfig.is_phone" class="h-left back-btn">
            <i class="iconfont icon-fanhui"></i>
        </a>
        <h1 class="h-title">
            订单详情
        </h1>
    </header>

    <form method="post" id="gotopay_form">
        <div id="root" class="h-t-bar">
            <div class="service-charge order-detail-status">
                发货状态：
                <span v-if="orderinfo.goods_status==0">未发货</span>
                <span v-if="orderinfo.goods_status==1">正在备货</span>
                <span v-if="orderinfo.goods_status==2">已发货</span>
                <span v-if="orderinfo.goods_status==3">已收货</span>
                <span v-if="orderinfo.goods_status==4">已完成</span>
                &nbsp;&nbsp;&nbsp;付款状态：
                <span v-if="orderinfo.status==0" >未付款</span>
                <span v-if="orderinfo.status==1" >已付款</span>
                <span v-if="orderinfo.status==-1" >已取消</span>
                <span v-if="orderinfo.status==-2" >正在退款</span>
                <span v-if="orderinfo.status==-3" >已退款</span>
            </div>
            <div class="pay-btn-group border-top">

                <button type="button" class="open-payorder-btn" v-if="orderinfo.dispute_step!=0" @click="open_dispute_orders(orderinfo)">查看所有投诉</button>
                <button type="button" class="delete-payorder-btn" @click="refused_order(orderinfo)"
                        v-if="orderinfo.status==1&&orderinfo.goods_status==0">退货
                </button>
                <button type="button" class="delete-payorder-btn" @click="delete_payorder(orderinfo.pay_order_id)"
                        v-if="orderinfo.status==0">取消订单</button>
                <button type="button" class="open-payorder-btn" @click="open_payorder(orderinfo.pay_order_id)"
                        v-if="orderinfo.status==0">去支付</button>

                <button class="open-payorder-btn" type="button" v-if="orderinfo.goods_status==2&&orderinfo.status!=-3&&orderinfo.status!=-2" @click="make_goods_order(orderinfo)">
                    确认收货{{shengyudays(orderinfo)}}
                </button>
                <button class="open-payorder-btn" type="button" v-if="orderinfo.goods_status==3" @click="make_goods_order(orderinfo)">
                    完成订单
                </button>

                <button class="open-payorder-btn" type="button"  @click="chat_to_live()">联系客服
                </button>
                <button class="open-payorder-btn" type="button" v-if="orderinfo.goods_status>2" @click="go_to_pingjia()">评价
                </button>
            </div>
            <div class="pay-gs-list g-wrap margin-bottom">
                <!--<div class="order-info">-->
                <!--<div class="order-price">-->
                <!--<img :src="orderinfo.user__icon_url+'&imageView2/1/w/40/h/40'" class="head-img">-->
                <!--<span v-text="">{{orderinfo.user__realname}}</span>-->
                <!--</div>-->
                <!--</div>-->

                <div v-for="goodsitem in goods_order_item">
                    <div class="g-item" @click="go_goods_detail(goodsitem.goods_id)">
                        <div class="g-item-wrap">
                            <span class="g-img">
                                <img :src="baseConfig.qn_host+goodsitem.small_image__fileurl+'?imageView2/1/w/70/h/70'">
                            </span>
                            <div class="g-i-info">
                                <p class="g-i-name order-goods-title">{{goodsitem.name}}</p>
                                <p class="order-goods-mark margin-bottom" v-if="goodsitem.gg">{{goodsitem.gg}}</p>
                                <p class="order-goods-mark"v-if="goodsitem.bz" v-text="'备注:'+goodsitem.bz"></p>
                                <p class="order-goods-mark" v-if="goodsitem.id">商品ID:{{goodsitem.goods_id}}</p>
                                <p class="order-count">
                                    <span class="order-goods-price" v-text="price_filter(goodsitem.price-goodsitem.bu_tie_price)"></span>
                                    <span class="order-goods-num">数量{{goodsitem.num}}</span>
                                </p>
                                <p class="order-count" v-if="orderinfo.goods_status!=0&&orderinfo.goods_status!=4&&orderinfo.status!=-3">
                                    <span class="order-goods-price" ></span>
                                    <span class="order-goods-num">
                                        <button class="delete-payorder-btn" type="button" @click.stop="dispute_goods_order_item(goodsitem)"   >
                                            <span v-if="!goodsitem.dispute_id">投诉</span>
                                            <span v-if="goodsitem.dispute_id">已投诉</span>
                                        </button>
                                    </span>
                                </p>
                            </div>
                        </div>
                    </div>
                    <div class="g-item-bz" ></div>
                </div>
                <div class=" padding-1">
                    <div class="order-list ">
                        <div class="left">商品总价：</div>
                        <div class="right price"><span v-text="price_filter(orderinfo.price-orderinfo.bu_tie_price)"></span></div>
                    </div>
                </div>
                <div class=" padding-1">
                    <div class="order-list ">
                        <div class="left">运费：</div>
                        <div class="right price"><span v-text="price_filter(orderinfo.express_fee-orderinfo.bu_tie_express_price)"></span></div>
                    </div>
                </div>

                <div class=" padding-1">
                    <div class="order-list ">
                        <div class="left">订单总额：</div>
                        <div class="right price"><span v-text="price_filter(orderinfo.express_fee+orderinfo.price-orderinfo.bu_tie_price-orderinfo.bu_tie_express_price)"></span></div>
                    </div>
                </div>
            </div>
            <div class="padding-1 white">
                <div class="order-list">
                    <div class="left">订单号：</div>
                    <div class="right">{{orderinfo.id}}</div>
                </div>
            </div>
            <div class="padding-1 white" v-if="orderinfo.goods_status>1">
                <div class="order-list">
                    <div class="left">发货时间：</div>
                    <div class="right">{{orderinfo.shipped_date}}</div>
                </div>
            </div>
            <div class="padding-1 white" v-if="orderinfo.goods_status>1">
                <div class="order-list">
                    <div class="left">快递公司：</div>
                    <div class="right">
                        <span v-if="orderinfo.express__name">{{orderinfo.express__name}}</span>
                        <span v-if="!orderinfo.express__name">{{orderinfo.express_name}}</span>
                    </div>
                </div>
            </div>
            <div class="padding-1 white" v-if="orderinfo.goods_status>1">
                <div class="order-list">
                    <div class="left">快递单号：</div>
                    <div class="right">{{orderinfo.express_no}}</div>
                </div>
            </div>
            <div class="padding-1 white" v-if="orderinfo.express_no&&orderinfo.goods_status>1">
                <div class="express-list" v-for="express_item in express_record_list">
                    <div class="top">{{express_item.context}}</div>
                    <div class="bottom">{{express_item.time}}</div>

                </div>
            </div>
            <div class="padding-1 white">
                <div class="order-list">
                    <div class="left">收件人:</div>
                    <div class="right">{{orderinfo.receiver_name}}</div>
                </div>
            </div>
            <div class="padding-1 white">
                <div class="order-list">
                    <div class="left">电话：</div>
                    <div class="right">{{orderinfo.receiver_phone}}</div>
                </div>
            </div>
            <div class="padding-1 white">
                <div class="order-list">
                    <div class="left">邮寄地址：</div>
                    <div class="">
                        {{orderinfo.receiver_province_name}}{{orderinfo.receiver_city_name}}{{orderinfo.receiver_county_name}}{{orderinfo.receiver_address_detail}}
                    </div>
                </div>
            </div>
            <div class="padding-1 white">
                <div class="order-list">
                    <div class="left">付款状态：</div>
                    <div class="right">
                        <span v-if="orderinfo.status==0" >未付款</span>
                        <span v-if="orderinfo.status==1" >已付款</span>
                        <span v-if="orderinfo.status==-1" >已取消</span>
                        <span v-if="orderinfo.status==-2" >正在退款</span>
                        <span v-if="orderinfo.status==-3" >已退款</span>
                    </div>
                </div>
            </div>
            <div class="padding-1 white" v-if="orderinfo.status==1">
                <div class="order-list">
                    <div class="left">付款时间：</div>
                    <div class="right">{{orderinfo.pay_date}}</div>
                </div>
            </div>
            <div class="padding-1 white" v-if="orderinfo.status==-3||orderinfo.status==-2">
                <div class="order-list">
                    <div class="left">退货方式：</div>
                    <div class="right" v-if="orderinfo.refund_type==1">用户退货</div>
                    <div class="right" v-if="orderinfo.refund_type==2">商家退货</div>
                    <div class="right" v-if="orderinfo.refund_type==3">平台退货</div>
                </div>
            </div>
            <div class="padding-1 white" v-if="orderinfo.dispute_step!=0">
                <div class="order-list">
                    <div class="left">投诉进度：</div>
                    <div class="right" v-if="orderinfo.dispute_step==1">提交投诉</div>
                    <div class="right" v-if="orderinfo.dispute_step==2">正在受理</div>
                    <div class="right" v-if="orderinfo.dispute_step==3">投诉解决</div>
                </div>
            </div>
            <!--<div class="padding-1 white" v-if="orderinfo.dispute_step!=0">-->
                <!--<div class="order-list">-->
                    <!--<div class="left">投诉方式：</div>-->
                    <!--<div class="right" v-if="orderinfo.dispute_type==1">用户投诉</div>-->
                    <!--<div class="right" v-if="orderinfo.dispute_type==2">主播投诉</div>-->
                    <!--<div class="right" v-if="orderinfo.dispute_type==3">系统自检</div>-->
                <!--</div>-->
            <!--</div>-->
            <!--<div class="padding-1 white">-->
                <!--<div class="order-list">-->
                    <!--<div class="left">发货状态：</div>-->
                    <!--<div class="right">-->
                        <!--<span v-if="orderinfo.goods_status==0">未发货</span>-->
                        <!--<span v-if="orderinfo.goods_status==1">正在备货</span>-->
                        <!--<span v-if="orderinfo.goods_status==2">已发货</span>-->
                        <!--<span v-if="orderinfo.goods_status==3">已收货</span>-->
                        <!--<span v-if="orderinfo.goods_status==4">已完成</span>-->

                    <!--</div>-->
                <!--</div>-->
            <!--</div>-->

            <div class="padding-1 white" v-if="orderinfo.goods_status>2">
                <div class="order-list">
                    <div class="left">收货时间：</div>
                    <div class="right">{{orderinfo.received_date}}</div>
                </div>
            </div>
            <div class="padding-1 white" v-if="orderinfo.goods_status>3">
                <div class="order-list">
                    <div class="left">完成时间：</div>
                    <div class="right">{{orderinfo.complete_date}}</div>
                </div>
            </div>
            <div class="padding-1 white" v-if="orderinfo.is_out">
                <div class="order-list">
                    <div class="left">身份证正面:</div>
                    <div class="right">

                    </div>
                </div>
            </div>
            <img :src="baseConfig.qn_host+orderinfo.id_img_1__fileurl" width="100%" v-if="orderinfo.is_out">
            <div class="padding-1 white" v-if="orderinfo.is_out">
                <div class="order-list">
                    <div class="left">身份证反面:</div>
                    <div class="right">
                    </div>
                </div>
            </div>
            <img :src="baseConfig.qn_host+orderinfo.id_img_2__fileurl" width="100%" v-if="orderinfo.is_out">
            <div class="padding-1 white goods-block"  v-if="orderinfo.buy_video_id">
<!--                <div class="goods-block-img">-->
<!--                    <video  :src="baseConfig.qn_host + orderinfo.buy_video__fileurl" x-webkit-airplay="true" x5-video-player-type="h5" controls="controls"></video>-->

<!--                </div>-->

                <div class="goods-block-img" v-for="img in orderinfo.buy_files_json_obj" @click="show_big_pengyou_img(orderinfo.buy_files_json_obj, img.fileurl)">
                    <img :src="img.url + '&imageView2/1/w/120/h/120'">
                </div>

            </div>
            <div class="padding-1 white" v-if="orderinfo.status==0">
                <div class="order-list">
                    <div class="left" style="color:red;">一小时内未完成支付，订单自动取消</div>
                </div>
            </div>

        </div>
    </form>
    <div  v-if="show_pengyou_dongtai_images">
        <div class="pswp" id="all_hundan_images" tabindex="-1" role="dialog" aria-hidden="true">

            <!-- Background of PhotoSwipe.
                 It's a separate element as animating opacity is faster than rgba(). -->
            <div class="pswp__bg"></div>

            <!-- Slides wrapper with overflow:hidden. -->
            <div class="pswp__scroll-wrap">

                <!-- Container that holds slides.
                    PhotoSwipe keeps only 3 of them in the DOM to save memory.
                    Don't modify these 3 pswp__item elements, data is added later on. -->
                <div class="pswp__container">
                    <div class="pswp__item"></div>
                    <div class="pswp__item"></div>
                    <div class="pswp__item"></div>
                </div>

                <!-- Default (PhotoSwipeUI_Default) interface on top of sliding area. Can be changed. -->
                <div class="pswp__ui pswp__ui--hidden">

                    <div class="pswp__top-bar">

                        <!--  Controls are self-explanatory. Order can be changed. -->

                        <div class="pswp__counter"></div>

                        <button class="pswp__button pswp__button--close" title="Close (Esc)"></button>


                        <!-- Preloader demo http://codepen.io/dimsemenov/pen/yyBWoR -->
                        <!-- element will get class pswp__preloader--active when preloader is running -->
                        <div class="pswp__preloader">
                            <div class="pswp__preloader__icn">
                                <div class="pswp__preloader__cut">
                                    <div class="pswp__preloader__donut"></div>
                                </div>
                            </div>
                        </div>
                    </div>

                    <div class="pswp__share-modal pswp__share-modal--hidden pswp__single-tap">
                        <div class="pswp__share-tooltip"></div>
                    </div>

                    <button class="pswp__button pswp__button--arrow--left" title="Previous (arrow left)">
                    </button>

                    <button class="pswp__button pswp__button--arrow--right" title="Next (arrow right)">
                    </button>

                    <div class="pswp__caption">
                        <div class="pswp__caption__center"></div>
                    </div>

                </div>

            </div>

        </div>
    </div>
</div>

</body>
</html>